import chisel3._
import chiseltest._
import org.scalatest.flatspec.AnyFlatSpec

class SimpleTestExpect extends AnyFlatSpec with ChiselScalatestTester {
    "DUT" should "pass" in {
        test(new PopCount) { dut =>
            dut.clock.step()
            dut.io.din.poke("b10010011".U)
            dut.io.dinValid.poke(true.B)

            for (a <- 0 until 12) {
                dut.clock.step()
            }
            dut.io.popCountReady.poke(true.B)
            dut.clock.step()
            dut.clock.step()
            dut.clock.step()
            dut.clock.step()
        }
    }
}




